package com.ywk.pattern._14_observer._14_2;

public class Main {
    public static void main(String[] args) {
        Secretary secretary = new Secretary();
        StockObserver stockObserver1 = new StockObserver("杨", secretary);
        StockObserver stockObserver2 = new StockObserver("李", secretary);

        secretary.Attach(stockObserver1);
        secretary.Attach(stockObserver2);

        secretary.setAction("老板回来了");
        secretary.Notify();


    }
}
